extern "C"
{
#include "libavcodec/avcodec.h"
#include "libavformat/avformat.h"
#include "libavutil/avutil.h"
#include "libswscale/swscale.h"
};

#include <string>
using namespace std;

class H264FileParser
{
public:
	H264FileParser();
	~H264FileParser();

public:
	int open(const string& p_strFileName);
	int getAVPacket(AVPacket* & p_pobjAVPacket);
	void close();

private:
	AVFormatContext*	pFormatCtx;
	AVCodecContext*		pCodecCtx;
	AVPacket*			packet;
};
